<template>
  <view class="agent-index">
    <uni-section title="代理中心" type="line">
      <template v-slot:right>
        <uni-icons class="user-icon" type="person" size="30" color="#1aad19"></uni-icons>
         <Logout />
      </template>
    </uni-section>

    <button @click="navigateTo('/pages/agent/profile')">个人资料</button>
    <button @click="navigateTo('/pages/agent/orders')">我的订单</button>
  </view>
</template>

<script>
import { agentRedirectionMixin } from '@/common/commonMixins.js';
import Logout from '@/components/logout.vue';
export default {
  mixins: [agentRedirectionMixin],
  components: {
    Logout
  },
  methods: {
    navigateTo(url) {
      uni.navigateTo({ url });
    }
  }
};
</script>
<style scoped lang="scss">

.user-icon {
  display: inline-block;
  vertical-align: middle;
  margin-right: 10rpx;
}
</style>